package com.foftact.block;

import java.math.BigDecimal;
import java.util.Date;

/**
 * 板块列表模型类
 * 对应数据库表：block
 */
public class Block {
    private Long id;             // 主键ID
    private String code;         // 板块代码
    private String name;         // 板块名称
    private String marketCode;  // 市场码
    private Long volume;         // 成交量(股)
    private Long amount;         // 成交额(元)
    private BigDecimal changePercent; // 涨跌幅(%)
    private String dataSource;   // 数据来源
    private Date updateTime;     // 更新时间
    private Boolean valid;       // 有效标志

    // getter和setter方法
    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getMarketCode() {
        return marketCode;
    }

    public void setMarketCode(String marketCode) {
        this.marketCode = marketCode;
    }

    public Long getVolume() {
        return volume;
    }

    public void setVolume(Long volume) {
        this.volume = volume;
    }

    public Long getAmount() {
        return amount;
    }

    public void setAmount(Long amount) {
        this.amount = amount;
    }

    public BigDecimal getChangePercent() {
        return changePercent;
    }

    public void setChangePercent(BigDecimal changePercent) {
        this.changePercent = changePercent;
    }

    public String getDataSource() {
        return dataSource;
    }

    public void setDataSource(String dataSource) {
        this.dataSource = dataSource;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public Boolean getValid() {
        return valid;
    }

    public void setValid(Boolean valid) {
        this.valid = valid;
    }

    @Override
     public String toString() {
         return "Block{" +
                 "id=" + id +
                 ", code='" + code + "'" +
                 ", name='" + name + "'" +
                 ", marketCode='" + marketCode + "'" +
                 ", changePercent=" + changePercent +
                 ", updateTime=" + updateTime +
                 ", valid=" + valid +
                 '}';
     }
}